package tech.aistar.service;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import tech.aistar.mapper.OrderMapper;
import tech.aistar.pojo.entity.Orders;

import java.util.List;

@Service
@Transactional
public class OrderServicelmpl implements OrderService{
    @Autowired
    private OrderMapper orderMapper;
    @Override
    public void ins(int userid, String ordernum, int orderstatus, String orderprice,String paidamount, String vip, int vipstatus, String createtime) {
        orderMapper.ins(userid,ordernum,orderstatus,orderprice,paidamount,vip,vipstatus,createtime);
    }

    @Override
    public Orders seltid(int uid) {
        return orderMapper.seltid(uid);
    }

    @Override
    public Orders seltonum(String ordernum) {
        return orderMapper.seltonum(ordernum);
    }

    @Override
    public void updat(int orderstatus, String paidmount, String vip, int vipstatus, String createtime,String ordernum) {
        orderMapper.updat(orderstatus,paidmount,vip,vipstatus,createtime,ordernum);
    }
}
